package com.ruoyi.service.impl;

import com.ruoyi.common.annotation.DataScope;
import com.ruoyi.domain.ParkingRecordOut;
import com.ruoyi.mapper.ParkingRecordOutMapper;
import com.ruoyi.service.IParkingRecordOutService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 车辆出场记录Service业务层处理
 * 
 * @author dongdong
 * @date 2025-08-23
 */
@Service
public class ParkingRecordOutServiceImpl implements IParkingRecordOutService 
{
    @Resource
    private ParkingRecordOutMapper parkingRecordOutMapper;

    /**
     * 查询车辆出场记录
     * 
     * @param id 车辆出场记录主键
     * @return 车辆出场记录
     */
    @Override
    public ParkingRecordOut selectParkingRecordOutById(String id)
    {
        return parkingRecordOutMapper.selectParkingRecordOutById(id);
    }

    /**
     * 查询车辆出场记录列表
     * 
     * @param parkingRecordOut 车辆出场记录
     * @return 车辆出场记录
     */
    @Override
    @DataScope(deptAlias = "pro")
    public List<ParkingRecordOut> selectParkingRecordOutList(ParkingRecordOut parkingRecordOut)
    {
        return parkingRecordOutMapper.selectParkingRecordOutList(parkingRecordOut);
    }

    /**
     * 新增车辆出场记录
     * 
     * @param parkingRecordOut 车辆出场记录
     * @return 结果
     */
    @Override
    public int insertParkingRecordOut(ParkingRecordOut parkingRecordOut)
    {
        return parkingRecordOutMapper.insertParkingRecordOut(parkingRecordOut);
    }

    /**
     * 修改车辆出场记录
     * 
     * @param parkingRecordOut 车辆出场记录
     * @return 结果
     */
    @Override
    public int updateParkingRecordOut(ParkingRecordOut parkingRecordOut)
    {
        return parkingRecordOutMapper.updateParkingRecordOut(parkingRecordOut);
    }

    /**
     * 批量删除车辆出场记录
     * 
     * @param ids 需要删除的车辆出场记录主键
     * @return 结果
     */
    @Override
    public int deleteParkingRecordOutByIds(String[] ids)
    {
        return parkingRecordOutMapper.deleteParkingRecordOutByIds(ids);
    }

    /**
     * 删除车辆出场记录信息
     * 
     * @param id 车辆出场记录主键
     * @return 结果
     */
    @Override
    public int deleteParkingRecordOutById(String id)
    {
        return parkingRecordOutMapper.deleteParkingRecordOutById(id);
    }

}
